function main(){
    debugger
    const self = this;
    let recId = this.cValue;
    getMatterRelSetBasis(recId).then(res => {
        debugger
        let selectItemEle = self.$$("table_40gghs");
        selectItemEle.onRefresh();
    })



}

function getMatterRelSetBasis(recId){
    let params =[{
        name: "recId",
        valueContent: recId
    }];
    return new Promise((resolve, reject) => {
        api.DATA_SOURCE_EXECUTE("ds_mod:b6526138-0326-4ed9-9146-1a79db1d0970", "ddcat", params, [], "").then(res => {
            debugger

            const newItems = res.result.map(item => ({
                rec_id: item.rec_id,
                rec_task_num: item.rec_task_num,
                matter_id: item.matter_id,
                rec_rel_matter_name: item.rec_rel_matter_name,
                law_code: item.law_code,
                law_name: item.law_name,
                law_set_basis_type_code: item.law_set_basis_type_code,
                law_set_basis_type_name: item.law_set_basis_type_name,
                law_item_id: item.law_item_id,
                law_item_code: item.law_item_code,
                law_item_name: item.law_item_name,
                law_item_info: item.law_item_info,
                opt_type: item.opt_type,
                document_id: item.law_set_basis_type_code + item.law_item_id,
            }));
        });

        window.selectMatter = newItems;
    });


}
